package com.yunkont.pigcontrol.bean;

import java.util.List;

/**
 * Created by bomei on 2017/9/23.
 */

public class PigBean {


    /**
     * _embedded : {"pigDatas":[{"time":1505850823267,"ax":0.0619,"ay":-0.2778,"az":0.2158,"wx":1.5286,"wy":-0.7832,"wz":1.1515,"hx":-21,"hy":-102,"hz":156,"posture":3,"pigId":"LVGB","angleX":3.1217,"angleY":0.7646,"angleZ":99.0604,"_links":{"self":{"href":"https://e5ba8c3a.ngrok.io/api/v1/pigDatas/4462"},"pigData":{"href":"https://e5ba8c3a.ngrok.io/api/v1/pigDatas/4462"}}}]}
     * _links : {"first":{"href":"https://e5ba8c3a.ngrok.io/api/v1/pigDatas/search/findByPigId?pigId=LVGB&_=1506153932100&page=0&size=1&sort=id,desc"},"self":{"href":"https://e5ba8c3a.ngrok.io/api/v1/pigDatas/search/findByPigId?pigId=LVGB&_=1506153932100&page=0&size=1&sort=id,desc"},"next":{"href":"https://e5ba8c3a.ngrok.io/api/v1/pigDatas/search/findByPigId?pigId=LVGB&_=1506153932100&page=1&size=1&sort=id,desc"},"last":{"href":"https://e5ba8c3a.ngrok.io/api/v1/pigDatas/search/findByPigId?pigId=LVGB&_=1506153932100&page=684&size=1&sort=id,desc"}}
     * page : {"size":1,"totalElements":685,"totalPages":685,"number":0}
     */

    private EmbeddedBean _embedded;
    private LinksBeanX _links;
    private PageBean page;

    public EmbeddedBean get_embedded() {
        return _embedded;
    }

    public void set_embedded(EmbeddedBean _embedded) {
        this._embedded = _embedded;
    }

    public LinksBeanX get_links() {
        return _links;
    }

    public void set_links(LinksBeanX _links) {
        this._links = _links;
    }

    public PageBean getPage() {
        return page;
    }

    public void setPage(PageBean page) {
        this.page = page;
    }

    public static class EmbeddedBean {
        private List<PigDatasBean> pigDatas;

        public List<PigDatasBean> getPigDatas() {
            return pigDatas;
        }

        public void setPigDatas(List<PigDatasBean> pigDatas) {
            this.pigDatas = pigDatas;
        }

        public static class PigDatasBean {
            /**
             * time : 1505850823267
             * ax : 0.0619
             * ay : -0.2778
             * az : 0.2158
             * wx : 1.5286
             * wy : -0.7832
             * wz : 1.1515
             * hx : -21
             * hy : -102
             * hz : 156
             * posture : 3
             * pigId : LVGB
             * angleX : 3.1217
             * angleY : 0.7646
             * angleZ : 99.0604
             * _links : {"self":{"href":"https://e5ba8c3a.ngrok.io/api/v1/pigDatas/4462"},"pigData":{"href":"https://e5ba8c3a.ngrok.io/api/v1/pigDatas/4462"}}
             */

            private long time;
            private double ax;
            private double ay;
            private double az;
            private double wx;
            private double wy;
            private double wz;
            private int hx;
            private int hy;
            private int hz;
            private int posture;
            private String pigId;
            private double angleX;
            private double angleY;
            private double angleZ;
            private LinksBean _links;

            public long getTime() {
                return time;
            }

            public void setTime(long time) {
                this.time = time;
            }

            public double getAx() {
                return ax;
            }

            public void setAx(double ax) {
                this.ax = ax;
            }

            public double getAy() {
                return ay;
            }

            public void setAy(double ay) {
                this.ay = ay;
            }

            public double getAz() {
                return az;
            }

            public void setAz(double az) {
                this.az = az;
            }

            public double getWx() {
                return wx;
            }

            public void setWx(double wx) {
                this.wx = wx;
            }

            public double getWy() {
                return wy;
            }

            public void setWy(double wy) {
                this.wy = wy;
            }

            public double getWz() {
                return wz;
            }

            public void setWz(double wz) {
                this.wz = wz;
            }

            public int getHx() {
                return hx;
            }

            public void setHx(int hx) {
                this.hx = hx;
            }

            public int getHy() {
                return hy;
            }

            public void setHy(int hy) {
                this.hy = hy;
            }

            public int getHz() {
                return hz;
            }

            public void setHz(int hz) {
                this.hz = hz;
            }

            public int getPosture() {
                return posture;
            }

            public void setPosture(int posture) {
                this.posture = posture;
            }

            public String getPigId() {
                return pigId;
            }

            public void setPigId(String pigId) {
                this.pigId = pigId;
            }

            public double getAngleX() {
                return angleX;
            }

            public void setAngleX(double angleX) {
                this.angleX = angleX;
            }

            public double getAngleY() {
                return angleY;
            }

            public void setAngleY(double angleY) {
                this.angleY = angleY;
            }

            public double getAngleZ() {
                return angleZ;
            }

            public void setAngleZ(double angleZ) {
                this.angleZ = angleZ;
            }

            public LinksBean get_links() {
                return _links;
            }

            public void set_links(LinksBean _links) {
                this._links = _links;
            }

            public static class LinksBean {
                /**
                 * self : {"href":"https://e5ba8c3a.ngrok.io/api/v1/pigDatas/4462"}
                 * pigData : {"href":"https://e5ba8c3a.ngrok.io/api/v1/pigDatas/4462"}
                 */

                private SelfBean self;
                private PigDataBean pigData;

                public SelfBean getSelf() {
                    return self;
                }

                public void setSelf(SelfBean self) {
                    this.self = self;
                }

                public PigDataBean getPigData() {
                    return pigData;
                }

                public void setPigData(PigDataBean pigData) {
                    this.pigData = pigData;
                }

                public static class SelfBean {
                    /**
                     * href : https://e5ba8c3a.ngrok.io/api/v1/pigDatas/4462
                     */

                    private String href;

                    public String getHref() {
                        return href;
                    }

                    public void setHref(String href) {
                        this.href = href;
                    }
                }

                public static class PigDataBean {
                    /**
                     * href : https://e5ba8c3a.ngrok.io/api/v1/pigDatas/4462
                     */

                    private String href;

                    public String getHref() {
                        return href;
                    }

                    public void setHref(String href) {
                        this.href = href;
                    }
                }
            }
        }
    }

    public static class LinksBeanX {
        /**
         * first : {"href":"https://e5ba8c3a.ngrok.io/api/v1/pigDatas/search/findByPigId?pigId=LVGB&_=1506153932100&page=0&size=1&sort=id,desc"}
         * self : {"href":"https://e5ba8c3a.ngrok.io/api/v1/pigDatas/search/findByPigId?pigId=LVGB&_=1506153932100&page=0&size=1&sort=id,desc"}
         * next : {"href":"https://e5ba8c3a.ngrok.io/api/v1/pigDatas/search/findByPigId?pigId=LVGB&_=1506153932100&page=1&size=1&sort=id,desc"}
         * last : {"href":"https://e5ba8c3a.ngrok.io/api/v1/pigDatas/search/findByPigId?pigId=LVGB&_=1506153932100&page=684&size=1&sort=id,desc"}
         */

        private FirstBean first;
        private SelfBeanX self;
        private NextBean next;
        private LastBean last;

        public FirstBean getFirst() {
            return first;
        }

        public void setFirst(FirstBean first) {
            this.first = first;
        }

        public SelfBeanX getSelf() {
            return self;
        }

        public void setSelf(SelfBeanX self) {
            this.self = self;
        }

        public NextBean getNext() {
            return next;
        }

        public void setNext(NextBean next) {
            this.next = next;
        }

        public LastBean getLast() {
            return last;
        }

        public void setLast(LastBean last) {
            this.last = last;
        }

        public static class FirstBean {
            /**
             * href : https://e5ba8c3a.ngrok.io/api/v1/pigDatas/search/findByPigId?pigId=LVGB&_=1506153932100&page=0&size=1&sort=id,desc
             */

            private String href;

            public String getHref() {
                return href;
            }

            public void setHref(String href) {
                this.href = href;
            }
        }

        public static class SelfBeanX {
            /**
             * href : https://e5ba8c3a.ngrok.io/api/v1/pigDatas/search/findByPigId?pigId=LVGB&_=1506153932100&page=0&size=1&sort=id,desc
             */

            private String href;

            public String getHref() {
                return href;
            }

            public void setHref(String href) {
                this.href = href;
            }
        }

        public static class NextBean {
            /**
             * href : https://e5ba8c3a.ngrok.io/api/v1/pigDatas/search/findByPigId?pigId=LVGB&_=1506153932100&page=1&size=1&sort=id,desc
             */

            private String href;

            public String getHref() {
                return href;
            }

            public void setHref(String href) {
                this.href = href;
            }
        }

        public static class LastBean {
            /**
             * href : https://e5ba8c3a.ngrok.io/api/v1/pigDatas/search/findByPigId?pigId=LVGB&_=1506153932100&page=684&size=1&sort=id,desc
             */

            private String href;

            public String getHref() {
                return href;
            }

            public void setHref(String href) {
                this.href = href;
            }
        }
    }

    public static class PageBean {
        /**
         * size : 1
         * totalElements : 685
         * totalPages : 685
         * number : 0
         */

        private int size;
        private int totalElements;
        private int totalPages;
        private int number;

        public int getSize() {
            return size;
        }

        public void setSize(int size) {
            this.size = size;
        }

        public int getTotalElements() {
            return totalElements;
        }

        public void setTotalElements(int totalElements) {
            this.totalElements = totalElements;
        }

        public int getTotalPages() {
            return totalPages;
        }

        public void setTotalPages(int totalPages) {
            this.totalPages = totalPages;
        }

        public int getNumber() {
            return number;
        }

        public void setNumber(int number) {
            this.number = number;
        }
    }
}
